<template>
   <view class="components-container">
       <h-card title="组件" margin="0 0 30rpx 0">
           <view class="item" v-for="(item,index) in list" :key="item.id" @click="goTo(item.path)">
			   {{index+1}}、{{item.name}}
		   </view>
       </h-card>
   </view>
</template>

<script>
    export default {
        name: "index",
		data: () => {
			return {
				list:[
					{ id:1, name:'轮播图', path:'/pages_sub1/components/swiper/index' },
                    { id:2,name:'上传', path:'/pages_sub1/components/upload/index'   },
					{ id:3,name:'mescroll列表', path:'/pages_sub1/components/mescroll/index' },
                    { id:4,name:'数字签名', path:'/pages_sub1/components/signature/index' },
                    { id:5,name:'扫码', path:'/pages_sub1/components/scanCode/index' },
                ]
			}
		},
        onLoad(){
            let _ = this
        },
        methods: {
            goTo(val){
                console.log('goTo')
                uni.$u.route(val)
            }
        }

    }
</script>

<style lang="scss" scope>
@import 'index.scss';
</style>
